package org.bonorsoft.modules.education.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.bonorsoft.modules.education.entity.Response;
import org.bonorsoft.modules.education.mapper.ResponseMapper;
import org.bonorsoft.modules.education.service.IResponseService;
import org.bonorsoft.modules.education.vo.ResponseVo;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Description: 通知回复表
 * @Author: WilliamYe
 * @Date:   2021-06-22
 * @Version: V1.0
 */
@Service
public class ResponseServiceImpl extends ServiceImpl<ResponseMapper, Response> implements IResponseService {

    @Override
    public int countByNoticeId(String noticeId,String addresseeName) {
        return this.baseMapper.countByNoticeId(noticeId,addresseeName);
    }

    @Override
    public List<ResponseVo> getResponseByNoticeId(String noticeId) {
        return this.baseMapper.getResponseByNoticeId(noticeId);
    }

    @Override
    public List<ResponseVo> getResponseByNoticeIdAndName(String noticeId, String addresseeName) {
        return this.baseMapper.getResponseByNoticeIdAndName(noticeId,addresseeName);
    }

    @Override
    public void removeByNoticeId(String noticeId) {
        this.baseMapper.removeByNoticeId(noticeId);
    }
}
